package ua.kharkov.khpi.tarasenko.bach.web.command.any;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import org.apache.log4j.Logger;

import ua.kharkov.khpi.tarasenko.bach.core.Constant;
import ua.kharkov.khpi.tarasenko.bach.web.command.Command;

/**
 * This command processing different errors.
 * 
 * @author oleksandr
 * 
 */
public class ErrorProcessingCommand extends Command {
	private static final Logger log = Logger
			.getLogger(ErrorProcessingCommand.class);

	@Override
	public String execute(HttpServletRequest request,
			HttpServletResponse response) {

		String forward = Constant.PAGE_ERROR;

		if (log.isDebugEnabled()) {
			log.debug("Forward to " + forward);
		}
		return forward;
	}
}
